package com.hgc.boot01.controller;

import com.hgc.boot01.pojo.User;
import com.hgc.boot01.service.HelloService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class HelloController {

    @Autowired
    //根据类型查找
    private HelloService helloService;

    @RequestMapping(value ="/post")
    public User getPost( User user) {
        System.out.println("User:"+user);
        return user ;
    }

}
